#pragma once

#include "board.h"
#include "moves.h"
#include "bitboard.h"

class MoveGenerator {
public:
	MoveGenerator();

	// spusti generovani tahu pro hrace "player" ze stavu hraci plochy "currentBoard"
	// generovane tahy se ukladaji do "storage"
	void Generate(CheckerColor player, Board currentBoard, Moves* storage);
private:
	CheckerColor player;;
	CheckerColor opponent;

	Board currentBoard;

	Moves* movesStorage;

	void generateNormalMoves();
	void generateQueenMoves();

	bool generateJumpsFrom(int from, bool directions[4], Move* tempStorage);
	void generateQueenMovesFrom(int from);
  void generateQueenJumpsFrom(int from, bool directions[4], Move tempStorage);


	Move* addMove(int from, int to);
	void addMove(Move* temp);
	void createTempStorage(Move* tempStorage);
};